package com.chen.learnknowledge.service;


import com.chen.learnknowledge.entity.User;

import java.io.IOException;
import java.util.List;

public interface UserService {

    Boolean getUserAllAndInsertIntoEs() throws IOException;

    void saveUserToEs(User user) throws IOException;

    void updateUserAndEs(User user) throws IOException;

    User getEsById(Integer id) throws IOException;

    void deleteEsById(Integer id) throws IOException;

    void bulkDeleteEs(List<Integer> ids) throws IOException;

    List<User> getAllFromEs() throws IOException;

    List<User> getUserFromEsByUserElement() throws IOException;

    List<User> getUserFromEsWithPage(Integer pageNum,Integer pageSize) throws IOException;

    List<User> getUserFromEsOrderByAge() throws IOException;

    List<User> getUserFromEsByElements() throws IOException;

    List<User> getUserFromEsByRange() throws IOException;

    List<User> getUserFromEsByFuzzyQuery() throws IOException;

    String getUserFromEsByMaxValue() throws IOException;

    String getUserFromEsByTerm() throws IOException;
}
